var t = require("./@babel/runtime/helpers/interopRequireDefault.js"), e = t(require("./@babel/runtime/helpers/typeof.js")), a = t(require("C65748722FB173BFA0312075CD44DCA6.js")), r = t(require("6B8040972FB173BF0DE62890FD84DCA6.js"));

module.exports = Behavior({
    lifetimes: {
        created: function() {
            this._computedCache = {}, this._originalSetData = this.setData, this.setData = this._setData, 
            this._doingSetData = !1;
        }
    },
    definitionFilter: function(t) {
        var i = t.computed || {}, o = Object.keys(i), s = function(t) {
            for (var e = {}, a = t._computedCache || t.data, s = 0, n = o.length; s < n; s++) {
                var l = o[s], c = i[l];
                if ("function" == typeof c) {
                    var u = c.call(t);
                    (0, r.default)(a[l], u) || (e[l] = u, a[l] = u);
                }
            }
            return e;
        };
        !function() {
            t.data = t.data || {};
            var r = t.data, i = t.properties, o = Object.prototype.hasOwnProperty;
            i && Object.keys(i).forEach(function(n) {
                var l, c = i[n];
                null === c || c === Number || c === String || c === Boolean || c === Object || c === Array ? i[n] = {
                    type: c
                } : "object" === (0, e.default)(c) && (o.call(c, "value") && (r[n] = c.value), o.call(c, "observer") && ("function" == typeof c.observer ? l = c.observer : "string" == typeof c.observer && (l = t.methods[c.observer]))), 
                i[n].observer = function() {
                    var t = this._originalSetData;
                    if (this._doingSetData) console.warn("can't call setData in computed getter function!"); else {
                        this._doingSetData = !0;
                        var e = s(this);
                        (0, a.default)(e) || t.call(this, e), this._doingSetData = !1;
                        for (var r = arguments.length, i = new Array(r), o = 0; o < r; o++) i[o] = arguments[o];
                        l && l.apply(this, i);
                    }
                };
            }), s(t);
        }(), t.methods = t.methods || {}, t.methods._setData = function(t, e) {
            var r = this._originalSetData;
            if (this._doingSetData) console.warn("can't call setData in computed getter function!"); else {
                this._doingSetData = !0;
                for (var o = Object.keys(t), n = 0, l = o.length; n < l; n++) {
                    var c = o[n];
                    i[c] && delete t[c];
                }
                r.call(this, t, e);
                var u = s(this);
                (0, a.default)(u) || r.call(this, u), this._doingSetData = !1;
            }
        };
    }
});